package javabase;
import java.util.Arrays;
public class Chapter_06_03 {

	public static void main(String[] args) {
		int[] numbers= {7,4,2,2,5,8,7,8,10};
		int[] numbers2=new int[9];
		int i,j,t=0;
		boolean isE=false;
		for(i=0;i<numbers.length;i++)
		{
			isE=false;
		   for(j=i+1;j<numbers.length;j++)
		   {
			   if(numbers[i]==numbers[j])
			   {
				   isE=true;
				   break;
			   }
		   }
		   if(isE==false)
		   {
			   numbers2[t]=numbers[i];
			   t++;
		   }
			
		}
		int numbers3[]=Arrays.copyOf(numbers2,t);
		System.out.print(Arrays.toString(numbers3));

	}

}
